<%@page import="util.Constants"%>
<%
    String title = (String) session.getAttribute("title_search");
    String statusID = (String) session.getAttribute("statusID_search");
    String severityID = (String) session.getAttribute("severityID_search");
    String priorityID = (String) session.getAttribute("priorityID_search");
    String logtypeID = (String) session.getAttribute("logtypeID_search");
%>
<div style="width: 100%; float: left;">
    Title
    <input type="text" id="txtTitle" name="txtTitle" size="20">
    <%
        if (title == null || title.isEmpty()) {
            out.print("");
        } else {
            out.print(title);
        }
    %>
    </input>

    Status
    <select size="1" name="cbxStatus">
        <%
            controller.defectLogController.loadStatusData(out, statusID);
        %>
    </select>

    Severity
    <select size="1" name="cbxSeverity">
        <%
            controller.defectLogController.loadSeverityData(out, severityID);
        %>	
    </select>

    Priority
    <select size="1" name="cbxPriority">
        <%
            controller.defectLogController.loadPriorityData(out, priorityID);
        %>	
    </select>

    Log Type
    <select size="1" name="cbxLogType">
        <%
            controller.defectLogController.loadLogtypeData(out, logtypeID);
        %>	
    </select>

    <a class="button" style="width: 32px; float: right; margin: 2px;" onclick="doAction(frmIndex,'<%=Constants.DEFECT_LOG_PAGE_NAME%>',
        '<%=Constants.DEFECTLOG_SEARCH%>','<%=Constants.DEFECTLOG_SEARCH%>',
        '<%=Constants.SEARCH%>')">Go</a>
    <a class="button" style="width: 32px; float: right; margin: 2px;" onclick="doAction(frmIndex,'<%=Constants.DEFECT_LOG_PAGE_NAME%>',
                '<%=Constants.DEFECTLOG_SEARCH%>','<%=Constants.DEFECTLOG_SEARCH%>',
                '<%=Constants.SHOW_ALL%>')">All</a>
</div>

<div style="width: 60%; float: left;">
    <%
        controller.defectLogController.showSearchResult(out, title, statusID, severityID, priorityID, logtypeID);
    %>
</div>
<div class="clear"></div>